<?php

class Orderdetail extends E_ARB {

	protected $belongs_to = array('product', 'performainvoice');
	protected $table_name = 'performainvoices_products';

	static function new_based_on( $product ) {
		$orderDetail					= new self();
		$orderDetail->product			= $product;
		$orderDetail->quantity			= 1;//doesny make that mush sece to me
		$orderDetail->price				= $product->price;
		$orderDetail->mounting_price	= -1;
		return $orderDetail;
	}

}

?>